package com.easylinkin.linkappapi.airconditioner.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName(value = "ac_host_device")
public class AirHostDevice extends Model<AirHostDevice> {
    /**
     * 设备编号
     */
    @TableId(value = "device_id", type = IdType.AUTO)
    private String deviceId;

    /**
     * 设备编码
     */
    @TableField(value = "device_code")
    private String deviceCode;

    /**
     * 设备名称
     */
    @TableField(value = "device_name")
    private String deviceName;

    /**
     * 电表设备编号
     */
    @TableField(value = "wattmeter_id")
    private String wattmeterId;

    /**
     * 当前开机状态 1:关机,2:开机
     */
    @TableField(value = "switch_state")
    private Integer switchState;

    /**
     * 创建时间
     */
    @TableField(value = "create_time")
    private Date createTime;

    /**
     * 更新时间
     */
    @TableField(value = "update_time")
    private Date updateTime;

    @TableField(exist = false)
    private List<AirconditionDevice> airconditionDeviceList;

    @TableField(exist = false)
    private List<AirconditionDeviceRecord> airconditionDeviceRecordList;

    /***
     * 查询开始时间
     */
    @TableField(exist = false)
    private Date queryStartTime;

    /***
     * 查询结束时间
     */
    @TableField(exist = false)
    private Date queryEndTime;

    /**
     * 低风P时长
     */
    @TableField(exist = false)
    private BigDecimal lowFanDuration=BigDecimal.ZERO;

    /**
     * 中风P时长
     */
    @TableField(exist = false)
    private BigDecimal midFanDuration=BigDecimal.ZERO;

    /**
     * 高风P时长
     */
    @TableField(exist = false)
    private BigDecimal highFanDuration=BigDecimal.ZERO;

    /***
     * 总耗能
     */
    @TableField(exist = false)
    private BigDecimal totalEnergy=BigDecimal.ZERO;

    @TableField(exist = false)
    private BigDecimal qaTotalEnergy=BigDecimal.ZERO;
    /***
     * 开机时长
     */
    @TableField(exist = false)
    private BigDecimal bootTime=BigDecimal.ZERO;

    @TableField(exist = false)
    private Double positiveActiveEnergy;

    @TableField(exist = false)
    private List<String> ids;

    @TableField("tenant_id")
    private String tenantId;//'租户id'

}